package com.fenghongzhang.kuaishou.widget;

import android.content.Context;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.widget.Toast;

import com.fenghongzhang.kuaishou.R;
import com.shuyu.gsyvideoplayer.video.StandardGSYVideoPlayer;

public class MyVideoPlayer extends StandardGSYVideoPlayer {


    public MyVideoPlayer(Context context) {
        super(context);
    }

    public MyVideoPlayer(Context context, AttributeSet attrs) {
        super(context, attrs);
    }

    //取消双击
    @Override
    protected void touchDoubleUp(MotionEvent e) {
//        super.touchDoubleUp(e);
        //添加瓢心的逻辑
    }

    //长按的逻辑
    @Override
    protected void touchLongPress(MotionEvent e) {
        super.touchLongPress(e);
        Toast.makeText(mContext, "哈哈", Toast.LENGTH_SHORT).show();
    }

    @Override
    protected void init(Context context) {
        super.init(context);
        //重写布局

    }

    @Override
    public int getLayoutId() {
        //重写布局
        return R.layout.my_player_layout;
    }
}
